In a three-dimensional memory device having a structure in which a plurality of electrode films is stacked on a substrate, a gap can be provided between electrode films vertically adjacent to each other. This gap can be formed by removing a sacrifice film by etching. A film that is not an object to be etched at this time needs to be formed of a proper material.